<html><head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8"><title>SpriteCollision</title></head>
<body bgcolor="#EFF1F0" link="#3A3966" vlink="#000000" alink="#000000">
<font face="Verdana, sans-serif" size="2"><p align="center"><b><font size="4">SpriteCollision()</font></b></p>
<p><b>语法</b></p><blockquote>

Result = <font color="#3A3966"><b>SpriteCollision</b></font>(#Sprite1, x1, y1, #Sprite2, x2, y2)</blockquote>

</blockquote>
<b>概要</b><br><blockquote>



Tests if the two sprites are overlapping. 

 

</blockquote><p><b>参数</b></p><blockquote>
<style type="text/css">
table.parameters { border-spacing: 0px; border-style: none; border-collapse: collapse; }
table.parameters td { border-width: 1px; padding: 6px; border-style: solid; border-color: gray; vertical-align: top; font-family:Arial; font-size:10pt; }
</style>
<table width="90%" class="parameters">
<tr><td width="10%"><i>#Sprite1</i></td>
<td width="90%"> 
 
The first sprite to test. 

 

</td></tr>
<tr><td><i>x1, y1</i></td>
<td> 
 
Coordinates of the first sprite, in pixels. 

 

</td></tr>
<tr><td><i>#Sprite2</i></td>
<td> 
 
The second sprite to test. 

 

</td></tr>
<tr><td><i>x2, y2</i></td>
<td> 
 
Coordinates of the second sprite, in pixels. 

 

</td></tr>
</table>
</blockquote><p><b>返回值</b></p><blockquote>



Nonzero if the two sprites are overlapping, zero otherwise. 

 

</blockquote><p><b>备注</b></p><blockquote>



This routine compares the rectangular areas around the sprites, giving a very fast 
but not very accurate function (depending on the shapes of your sprites). 
Very useful for fast arcade games. Zoomed sprites are also supported. 
<br>
<br>
For a more exact collision check use <a href="spritepixelcollision.html">SpritePixelCollision()</a>. 

 

</blockquote><p><b>参阅</b></p><blockquote>

<a href="spritepixelcollision.html">SpritePixelCollision()</a> 

</Blockquote><p><b>已支持操作系统 </b><Blockquote>所有</Blockquote></p><center>&lt;- <a href=spriteblendingmode.html>SpriteBlendingMode()</a> - <a href="index.html">Sprite Index</a> - <a href="spritedepth.html">SpriteDepth()</a> -&gt;<br><br>

</body></html>